﻿<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>@ViewBag.Title</title>
    <meta name="Keywords" content="@ViewBag.MetaKeywords" />
    <meta name="Description" content="@ViewBag.MetaDescription" />
    <base href="@Web.Infrastructure.Mvc.FileUpload.UploadManager.UrlPrefix" />
    <link rel="stylesheet" href="@Url.ThemeContent("~/Content/themes/"+ThemeManager.Style+"/reset.css")" />
    <link rel="stylesheet" href="@Url.ThemeContent("~/Content/themes/"+ThemeManager.Style+"/site.css")" />
    @{
        var setting = Application.AppEngine.Container.GetInstance<Application.Services.ISettingService>().GetSetting();
    }
    @if (!string.IsNullOrEmpty(setting.Css))
    {
        <style type="text/css">
        @Html.Raw(setting.Css)
        </style>
    }
    @RenderSection("head", false)
    @if (!string.IsNullOrEmpty(setting.Js))
    {
        @Html.Raw(setting.Js)
    }
</head>
<body>
    <div class="header">
        <div class="logo">
            <a href="@Url.Action("Index","Home")"><img alt="@setting.Name" src="@setting.LogoImageUrl" /></a>
        </div>
        <ul class="state">
            <li></li>
        </ul>
        @Html.Action("LoginPartial", "Account")
    </div>
    <div class="menu">
        <ul id="nav">
            <li><a @if (ViewBag.Menu == "home") { <text> class="current" </text>        } href="@Url.Action("Index","Home")">首页</a></li>
        </ul>
        <script>
            $(function () {
                $(" #nav ul ").css({ display: "none" }); // Opera Fix
                $(" #nav li").hover(function () {
                    $(this).find('ul:first').css({ visibility: "visible", display: "none" }).show(400);
                }, function () {
                    $(this).find('ul:first').css({ visibility: "hidden" });
                });
            });
        </script>
    </div>
    <div class="main">
        <div class="content">
            @RenderBody()
        </div>
    </div>
    <div class="footer">
        <div class="copyright">
            @setting.Copyright
        </div>
    </div>
</body>
</html>